//
//  XWeiboCell.m
//  SinaWeibo
//
//  Created by Apple on 16/8/18.
//  Copyright © 2016年 Apple. All rights reserved.
//

#import "XWeiboCell.h"
#import "StatuesModel.h"
#import "UserModel.h"
#import "PhotoCell.h"
#import "OriginalStatuesView.h"
#import "RetweetedStatuesView.h"
#import "FootView.h"

#define kMargin 10

@interface XWeiboCell()




//***************************************************************//
/*****                     原创微博属性                        *****/
//***************************************************************//


@property (weak, nonatomic) IBOutlet OriginalStatuesView *originalStatuesView;



//***************************************************************//
/*****                     转发微博属性                        *****/
//***************************************************************//

@property (weak, nonatomic) IBOutlet RetweetedStatuesView *retweetedStatuesView;


//***************************************************************//
/*****                     底部视图View                        *****/
//***************************************************************//

@property (weak, nonatomic) IBOutlet FootView *footView;


@end


@implementation XWeiboCell

-(void)setStatuesModel:(StatuesModel *)statuesModel{
    
    
    
    _statuesModel = statuesModel;
    
    self.originalStatuesView.statueModel = statuesModel;
    
    self.retweetedStatuesView.statueModel = statuesModel.retweeted_status;
    
    self.footView.statuesModel = statuesModel;
    
    
}


-(void)retweeted:(StatuesModel *)retweetedStatues{
    
    
    
}

-(CGFloat)cellHeightWithStatu:(StatuesModel *)statuesModel{
    
    self.statuesModel = statuesModel;
    
    [self layoutIfNeeded];
    
    return CGRectGetMaxY(self.footView.frame) + kMargin*0.5;
    
}





@end
